<template>

</template>

<script>


export default {
  name: "mapBox",
  data() {
    // let self = this;
    return {

    };
  },
  methods: {
    testClicks :function () {
        this.center =  [118.784078,32.088865] // 高德地图中心点
        console.log(this.center)
    }

  },
  mounted() {

    // const client = TRTC.createClient({
    //   mode: "live",
    //   sdkAppId: 1400376830,
    //   userId: "1380000002",
    //   userSig:
    //     "eJyrVgrxCdYrSy1SslIy0jNQ0gHzM1NS80oy0zLBwobGFgZgYASVLU7JTiwoyExRsjI0MTAwNjezMDaAyKRWFGQWpQLFTU1NjYA6IKIlmblgMUsDSwMTSwNTqCmZ6UDDi03zHJPMkrO9S0Ndkv39DVzCkzwDnByLCwxdDJ0inNODc8uqciPSE33MfW2VagFMejEr"
    // });
    // //先注册远端流
    // client.on("stream-added", event => {
    //   const remoteStream = event.stream;
    //   console.log("远端流增加: " + remoteStream.getId());
    //   //订阅远端流
    //   client.subscribe(remoteStream);
    // });
    // client.on("stream-subscribed", event => {
    //   const remoteStream = event.stream;
    //   console.log("远端流订阅成功：" + remoteStream.getId());
    //   // 播放远端流
    //   remoteStream.play("meBox");
    // });
    //
    // //创建房间
    // client
    //   .join({ roomId: 123123, anchor: "anchor" })
    //   .then(() => {
    //     // 从麦克风和摄像头采集本地音视频流
    //     const localStream = TRTC.createStream({ audio: true, video: true });
    //     localStream
    //       .initialize()
    //       .catch(error => {
    //         console.error("初始化本地流失败 " + error);
    //       })
    //       .then(() => {
    //         console.log("初始化本地流成功");
    //         localStream.play("yourBox");
    //         localStream.resume();
    //         client
    //           .publish(localStream)
    //           .catch(error => {
    //             console.error("本地流发布失败 " + error);
    //           })
    //           .then(() => {
    //             console.log("本地流发布成功");
    //           });
    //       });
    //   })
    //   .catch(error => {
    //     console.error("Join room failed: " + error);
    //   });
  }
};
</script>
<style lang="less">
</style>